const ws = new WebSocket('wss://47.121.28.202:8000/wss/buyinginformation/');  
  
ws.onopen = () => {  
  console.log('WebSocket连接已建立');  
};  
  
ws.onmessage = (event) => {  
  console.log('收到消息：', event.data);  
};  
  
ws.onclose = () => {  
  console.log('WebSocket连接已关闭');  
};  
  
ws.onerror = (error) => {  
  console.error('WebSocket错误：', error);  
};  

export default ws;
